package com.study.b02threadpool2;

import java.util.concurrent.ArrayBlockingQueue;
import java.util.concurrent.Executor;
import java.util.concurrent.Executors;
import java.util.concurrent.ThreadPoolExecutor;

/*public class MyThreadPoolDemo1 {
    public static void main(String[] args) {

        ThreadPoolExecutor pool=new ThreadPoolExecutor(

                3,//核心线程数量，能小于0
                6,//最大线程数量》=核心线程数量
                60,//线程空闲时间，单位秒
                TimeUnit.SECONDS,//时间单位
                new ArrayBlockingQueue<>(3),//阻塞队列
                Executors.defaultThreadFactory(),//线程工厂
                new ThreadPoolExecutor.AbortPolicy()//拒绝策略
        );

    }
}*/
